package com.gzy.rpsm_property.controller;

import com.gzy.rpsm_property.pojo.Building;
import com.gzy.rpsm_property.pojo.ResponsePojo;
import com.gzy.rpsm_property.service.BuildingService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@Api(tags = "楼栋相关API")
@RequestMapping("/building")
@RestController
public class BuildingController {
    @Autowired
    BuildingService buildingService;
    @GetMapping("/buildingOfUsed")

    @ApiOperation(value = "查询在用建筑的列表 ",responseContainer = "List")



            public ResponsePojo<List<Building>> buildingOfUsed(){
            return ResponsePojo.success(buildingService.buildingsOfUsed());
            }
}

